import React from 'react';
import {
  Form, Select,
} from 'antd';

const { Option } = Select;

export default function FlowForm({ closeModal, updateBPMN }) {
  const handleSelect = (value) => {
    closeModal();
    updateBPMN(value);
  };

  return (
    <Form
      labelCol={{ xs: { span: 24 }, sm: { span: 6 } }}
      wrapperCol={{
        xs: { span: 24 },
        sm: { span: 18 },
      }}
    >
      <Form.Item label="条件是否满足">
        <Select onSelect={handleSelect}>
          <Option value="yes">是</Option>
          <Option value="no">否</Option>
        </Select>
      </Form.Item>
    </Form>
  );
}
